(() => {
    const groups = document.querySelectorAll('.gd-btn-group')
    groups.forEach(group => {
        const btns = group.querySelectorAll('.gd-btn')
        btns.forEach(btn => {
            btn.addEventListener('click', e => {
                if(!btn.classList.contains('is-active')) {
                    group.querySelector('.is-active').classList.remove('is-active')
                    btn.classList.add('is-active')
                }
            })
        })
    })
})()